<?php
header("Content-type:text/html; charset=utf-8");
$mysqli = new mysqli('localhost:3306','root','','boke');
// $mysqli = new mysqli('localhost:3306','liuboyto_root','#MySQLmima#618','liuboyto_618');

mysqli_query($mysqli,"set names utf8");
$sql1 = "select count(*) from fenxiang where userid=1";
$res1 = $mysqli->query($sql1);
while ($row1 = $res1->fetch_assoc()) {
	$c[] =$row1; 
// print_r($row1) ;
	}
	echo json_encode($c);
$mysqli->close();
?>